<template>
  <div>
    <el-button @click="reqGet">get请求</el-button>
        <el-button @click="reqPost">post请求</el-button>
        <el-button @click="reqPut">put请求</el-button>
        <el-button @click="reqDelete">delete请求</el-button>
  </div>
</template>
  
<script>
import axios from 'axios'


export default {
  name: 'projectManagement',
  componentTitle: '专题管理',
  data () {
    return {}
  },
  methods:{
reqGet(){
  axios({
    url:'http://127.0.0.1:3000/',
    method:'get',
  }).then(res=>{
    console.log(res)
  })
},

reqPost(){
    axios({
    url:'http://127.0.0.1:3000/goods/add',
    method:'post',
  }).then(res=>{
    console.log(res)
  })
},

reqPut(){
      axios({
    url:'http://127.0.0.1:3000/goods/update',
    method:'put',
  }).then(res=>{
    console.log(res)
  })
},

reqDelete(){
      axios({
    url:'http://127.0.0.1:3000/goods/delete',
    method:'delete',
  }).then(res=>{
    console.log(res)
  })
},




  }


}
</script>
